package com.xuxueli.applyModules.utils.testquarts;
import lombok.extern.slf4j.Slf4j;
import org.quartz.*;

@Slf4j
public class ServiceBatchSearchJob implements Job {
    @Override
    public void execute(JobExecutionContext context) {
        JobKey jobKey = context.getJobDetail().getKey();
        log.info("定时任务开始: {},{}", jobKey.getGroup(), jobKey.getName());
        long beginTime = System.currentTimeMillis();
        JobDetail jobDetail = context.getJobDetail();
        JobDataMap jobDataMap = jobDetail.getJobDataMap();
        Long batchSearchId = jobDataMap.getLong("id");
        System.out.println(batchSearchId);
//        OracleService oracleService = SpringUtil.getBean(OracleService.class);
//        oracleService.listPlugins();
        log.info("耗时: {}", System.currentTimeMillis() - beginTime);
        log.info("定时任务结束: {},{}", jobKey.getGroup(), jobKey.getName());
    }
}